﻿using System;
using NUnit.Framework;

namespace WallpaperSharing.DataAccess.Test
{
    [TestFixture]
    public class DaoTestBase
    {
        [SetUp]
        public void BaseSetUp()
        {
            bool isStarted = DataSources.Manhattan.BeginTransaction();
            if (isStarted == false)
            {
                throw new Exception("Transaction not started.");
            }
        }

        [TearDown]
        public void BaseTearDown()
        {
            DataSources.Manhattan.RollBackTransaction();
        }
    }
}
